package br.com.mmm.javacenter.framework.security;

import java.security.Principal;
import java.util.Set;

public class UserPrincipal implements Principal{
    private String name;  
    private Set<Role> roles;  
      
    public UserPrincipal(String name){  
        this.name = name;  
    }  
      
    public String getName() {  
        return name;  
    }  
      
    public Set<Role> getRoles() {  
        return roles;  
    }  
  
    public void setRoles(Set<Role> roles) {  
        if (this.roles == null)  
            this.roles = roles;  
    }

}
